<?php
require_once realpath(dirname(__FILE__)) . '//..//..//pages.php';
require_once CLASS_RECORD;

/**
 * Description of Distretto
 *
 * @author Andrea Cantafio
 */
class Distretto extends Record {

    public function __construct ($values) {
        $data = array ();
        if (is_array ($values)) {
            foreach ($values as $key => $value) {
                $add = true;
                switch ($key) {
                    case 'ID':
                    case 'nome':
                    case 'descrizione':
                        break;
                    default:
                        $add = false;
                }
                if ($add) {
                    $data[$key] = $value;
                }
            }
        }
        $this->required[] = 'nome';
        parent::__construct ('distretto', $data);
    }

}

?>
